<%@ include file="/common/taglibs.jsp"%>

<head>
    <title><fmt:message key="commentDetail.title"/></title>
    <meta content="<fmt:message key='commentDetail.heading'/>"/>
</head>

<s:form id="commentForm" action="saveComment" method="post" validate="true">
    <s:hidden name="comment.id" value="%{comment.id}"/>
    <s:hidden name="issue.id" value="%{issue.id}"/>
    <s:textfield key="comment.author" required="true" cssClass="text medium"/>
    <s:textfield key="comment.createdDate" required="false" cssClass="text medium"/>
    <s:textarea key="comment.commentText" required="false" cssClass="text medium"/>

    <li class="buttonBar bottom">
        <s:submit cssClass="button" method="save" key="button.save" theme="simple"/>
        <c:if test="${not empty comment.id}">
            <s:submit cssClass="button" method="delete" key="button.delete" onclick="return confirmDelete('comment')" theme="simple"/>
        </c:if>
        <s:submit cssClass="button" method="cancel" key="button.cancel" theme="simple"/>
    </li>

</s:form>
